<template>
  <div class="piliangsousuo">
    <el-dialog :title="title" center :visible.sync="log" :close-on-click-modal="false" width="600px">
    	<div>
    		<el-input type="textarea" :rows="10" placeholder="一行一个，可直接粘贴excel纵列数据" v-model="ids"></el-input>
    	</div>
    	<div slot="footer" class="dialog-footer">
    		<el-button type="danger" round  @click="search">{{mingzi}}</el-button>
    	</div>
    </el-dialog>
  </div>
</template>

<script>
  export default {
    name: 'piliangsousuo',
    props:['title','ming'],
    data() {
      return {
        log:false,
        ids:[],
        title1:"",
        mingzi:'搜索'
      }
    },
    created() {
      if(this.ming){
        this.mingzi = this.ming
      }
      
    },
    methods:{
      search:function(){
        let ids = []
        ids = this.ids.split(/\n/)
        for (let i in ids) {
        	ids[i] = ids[i].trim()
        }

        this.$emit('qusousuo',ids.toString())
        this.log = false
      },
    }
  }
</script>

<style lang="scss" scoped>
  .piliangsousuo {


  }
</style>
